package com.lwc.cfdns.pojo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lwc.cfdns.pojo.BaseEntity;

import java.io.Serializable;
import java.time.LocalDateTime;

import com.lwc.cfdns.pojo.dto.ValidGroup;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 字典数据表
 *
 * @TableName cfdns_system_dict_data
 */
@TableName(value = "cfdns_system_dict_data")
@Data
public class SystemDictData extends BaseEntity implements Serializable {
    /**
     * 字典编码
     */
    @TableId(type = IdType.AUTO)
    @NotNull(message = "ID不能为空", groups = {ValidGroup.Update.class})
    private Long id;

    /**
     * 字典排序
     */
    private Integer sort;

    /**
     * 字典标签
     */
    @NotBlank(message = "字典标签不能为空", groups = {ValidGroup.Update.class, ValidGroup.Create.class})
    private String label;

    /**
     * 字典键值
     */
    @NotBlank(message = "字典键值不能为空", groups = {ValidGroup.Update.class, ValidGroup.Create.class})
    private String value;

    /**
     * 字典标识
     */
    @NotBlank(message = "字典标识不能为空", groups = {ValidGroup.Update.class, ValidGroup.Create.class})
    private String marks;

    /**
     * 样式属性（其他样式扩展）
     */
    private String cssClass;

    /**
     * 表格回显样式
     */
    private String listClass;

    /**
     * 是否默认（Y是 N否）
     */
    private String isDefault;

    /**
     * 状态（0正常 1停用）
     */
    private String status = "0";

    /**
     * 备注
     */
    private String remark;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}